package leetcode.weekly.week341;

//Solution1Test
public class Solution1 {

	public int[] rowAndMaximumOnes(int[][] mat) {
		int m = mat.length, n = mat[0].length;
		int ai = 0, av = 0;
		for (int i = 0; i < m; i++) {
			int sum = 0;
			for (int j = 0; j < n; j++) {
				sum += mat[i][j];
			}
			if (sum > av) {
				av = sum;
				ai = i;
			}
		}
		return new int[] {ai,av};
	}
}
